import os
import geopandas as gpd
import matplotlib.pyplot as plt
import pandas as pd

# import source data
geojson_folder = 'map'

# init GeoDataFrame
combined_gdf = gpd.GeoDataFrame()

for filename in os.listdir(geojson_folder):
    if filename.endswith('.geojson'):
        file_path = os.path.join(geojson_folder, filename)
        gdf = gpd.read_file(file_path)
        combined_gdf = pd.concat([combined_gdf, gdf], ignore_index=True)

fig, ax = plt.subplots(1, 1, figsize=(12, 8))
combined_gdf.plot(ax=ax, edgecolor='black', facecolor='none', alpha=0.5)

plt.title('Combined GeoJSON Map')
plt.xlabel('Longitude')
plt.ylabel('Latitude')

# plot map
plt.show()